import { default as request, cloud } from '@/framework/utils/request'

// 数据备份-获取备份配置详情
export function detailApi(data) {
  return request({
    url: cloud.interfacePlatform + '/backup/config/detail',
    method: 'get',
    params: data
  })
}

// 数据备份-保存备份配置
export function saveApi(data) {
  return request({
    url: cloud.interfacePlatform + '/backup/config/save',
    method: 'post',
    data
  })
}

// 数据备份-备份记录分页
export function pageApi(data) {
  return request({
    url: cloud.interfacePlatform + '/backup/log/page',
    method: 'get',
    params: data
  })
}

// 数据备份-手动备份
export function runApi(data) {
  return request({
    url: cloud.interfacePlatform + '/backup/run',
    method: 'get',
    params: data
  })
}

// 数据备份-删除备份记录
export function deleteApi(data) {
  return request({
    url: cloud.interfacePlatform + '/backup/log/delete',
    method: 'post',
    data
  })
}
